
/*
* 技能类
*/
Skill = function(name, key, harm, cd){
	this.name = name;
	this.key = key;
	this.harm = harm;
	this.cd = cd & 0;
	this.state = "cd"; // ready
}
/*
* 技能是否CD中
*/
Skill.prototype.isCD = function() {
	return this.state == "cd";
};
/*
* 放技能
*/
Skill.prototype.cast = function() {
	var tmpSkillObject = this;
	if (this.cd == 0) {return true};
	tmpSkillObject.state = "cd";
	setTimeout(function(){
		tmpSkillObject.state = "ready";
	}, this.cd*1000;
};